package cn.darkhorse.workorder.service;

import java.io.File;
import java.util.List;
import cn.darkhorse.workorder.domain.QmsWorkorder;
import cn.darkhorse.workorder.vo.QmsWorkorderVO;
import com.baomidou.mybatisplus.extension.service.IService;

/**
 * 流转单Service接口
 *
 * @author ytq
 * @date 2024-07-19
 */
public interface IQmsWorkorderService extends IService<QmsWorkorder>
{
    /**
     * 查询流转单
     *
     * @param id 流转单主键
     * @return 流转单
     */
    public QmsWorkorder selectQmsWorkorderById(Long id);

    /**
     * 查询流转单列表
     *
     * @param qmsWorkorder 流转单
     * @return 流转单集合
     */
    public List<QmsWorkorder> selectQmsWorkorderList(QmsWorkorder qmsWorkorder);

    /**
     * 新增流转单
     *
     * @param qmsWorkorder 流转单
     * @return 结果
     */
    public boolean saveQmsWorkorder(QmsWorkorder qmsWorkorder);


    /**
     * 批量删除流转单
     *
     * @param ids 需要删除的流转单主键集合
     * @return 结果
     */
    public int deleteQmsWorkorderByIds(Long[] ids);

    /**
     * 删除流转单信息
     *
     * @param id 流转单主键
     * @return 结果
     */
    public boolean deleteQmsWorkorderById(Long id);

    /**
     * 获取编号
     */
    public String getOrderNumber();

    /**
     * 数据上传
     * @param workorder
     * @return
     */
    public boolean doUpload(QmsWorkorder workorder);

    /**
     * 查看
     * @param id
     * @return
     */
    public QmsWorkorder view(Long id);

    /**
     * 查看流转单主体
     * @param id
     * @return
     */
    public QmsWorkorderVO viewMain(Long id);

    File findWorkOrderDetail(QmsWorkorder workorder,String img);
}
